import request from '../utils/request'


export const getNeedCaptcha = () => {
  return request({
    url: '/captcha/need',
    method: 'get'
  })
}

export const getCaptcha = query => {
  return request({
    url: '/captcha/code',
    method: 'get',
    params: query
  });
}

export const getCaptchaImage = () => {
  return request({
    url: '/captcha//code',
    method: 'get'
  })
}

export const systemLogin = (data) => {
  return request({
    url: '/system/login',
    method: 'post',
    data: data
  })
}

export const sendSmsCode = (data) => {
  return request({
    url: '/sms/send',
    method: 'post',
    data: data
  })
}